<%-- 
    Document   : jscripttest
    Created on : 13-apr-2012, 15:33:52
    Author     : BoonJ
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <title>
            JavaScript array print example
        </title>
        <script type="text/javascript">
                var arr = new Array(5);
                var msg = "";
                arr[0]="Rose";
                arr[1]="India";
                arr[2]="Technologies";
                arr[3]="Pvt";
                arr[4]="Ltd";
                for(var i=0;i<arr.length;i++){
                    msg=msg + arr[i] + "\n";
                    document.write(arr[i]+"<br>");
                }    
                alert(msg);
        </script>
    </head>
    <body>
        <h2>
            JavaScript array print
        </h2>
    </body>
</html>
